package itcast.bos.base.service;

import java.util.Date;

import javax.ws.rs.Consumes;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.QueryParam;

import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import itcast.bos.domain.base.PageBean;
import itcast.bos.domain.base.Promotion;

public interface PromotionService {

	void save(Promotion model);

	Page<Promotion> findPageData(Pageable pa);
	
	@GET
	@Path("/pageQuery")
	@Produces({"application/xml","application/json"})
	@Consumes({"application/xml","application/json"})
	PageBean<Promotion> pageQuery(@QueryParam("page")int page,@QueryParam("rows")int rows);
	
	@GET
	@Path("/findOne")
	@Produces({"application/xml","application/json"})
	@Consumes({"application/xml","application/json"})
	Promotion FindOne(@QueryParam("id") Integer id);
	
	//设置活动过期
	void updateStatus(Date date);
	

}
